<script src="/vendor/laravel-admin/AdminLTE/plugins/jQuery/jQuery-2.1.4.min.js"></script>
<script src="/vendor/laravel-admin/AdminLTE/bootstrap/js/bootstrap.min.js"></script>
<script src="/vendor/jquery/layer/layer.js"></script>
<script src="/vendor/laravel-admin/moment/min/moment-with-locales.min.js"></script>
<script src="/vendor/laravel-admin/eonasdan-bootstrap-datetimepicker/build/js/bootstrap-datetimepicker.min.js"></script>
<link rel="stylesheet" href="/vendor/laravel-admin/AdminLTE/bootstrap/css/bootstrap.min.css">
<link rel="stylesheet" href="/vendor/laravel-admin/eonasdan-bootstrap-datetimepicker/build/css/bootstrap-datetimepicker.min.css">
<style>
    div.panel {
        border: 1px solid blue;
        width: 850px;
        height: 550px;
        display: none;
        position: absolute;
        background: whitesmoke;
        z-index: 10;
    }


    div.panel-heading {
        height: 30px
    }

    div.panel-body {
        word-wrap: break-word;
        height: 500px;
        overflow: auto;
    }

    div.storeinfo {
        width: 192px;
        cursor: pointer;
        height: 250px;
        border: 1px solid black;
        float: left;
        overflow: auto;
        position: inherit;
    }
    div.storeinfo img{
        width: 190px;
    }
    span.close {
        float: right;
        color: red;
        cursor: pointer;
    }
    div.img_item {
        display: inline-block;
    }
</style>
<body class="J_scroll_fixed">

@foreach($picList as $key => $pic)
    <div style="width:317px; margin: 10px; border: 1px solid black;padding: 15px;" class="img_item">
        <img src="{{$pic['pic_url']}}" style="width:285px;" />
        <div class="img_item_goods" style="margin-top: 20px; ">
            <strong>点图标签 ：</strong>{{$pic['imgTag']}}
            <br>
            <strong>关联商品 ：</strong>
            @foreach($pic['relateList'] as $relate)
                <div style="width:100%;border-bottom: 1px solid black;" id="divgood_{{$relate['id']}}_{{$pic_id}}" photo-id="{{$pic_id}}" wiki-id="{{isset($relate['wiki']) ? $relate['wiki'] : ""}}"  type-id = "{{$relate['rela_type']}}" goods-id="{{$relate['id']}}">
                    <img src="{{$relate['cover_img']}}" height="50px" width="50px"/>
                    <span>
                                @php
                                    echo implode(' | ', [
                                        (isset($relate['wiki']) && ($relate['wiki'] > 0) ? 'wiki' : 'spu') ,
                                        $relate['id'],
                                        (isset($relate['brand_info']) && is_array($relate['brand_info']) ? "【".$relate['brand_info']['name']."】 " .$relate['title'] : $relate['title']),
                                    ]);
                                @endphp
                            </span>
                    <a data-id="delRel" class="copyLink" ><input type="hidden" value="{{$relate['url']}}">复制链接</a>
                    <a data-id="delRel" class="deleteRel" data-uid="{{$relate['id']}}_{{$pic_id}}">删除</a>
                </div>
            @endforeach
        </div>
        <div class="img_item_search" style="margin-top: 20px;">
            {{--<div class="input-group">--}}
                {{--<strong> spu关键词：</strong> <input type="text" class="form-control keywordSearch" style="width:263px">--}}
            {{--</div>--}}
            <div class="input-group">
                <strong> wiki关键词：</strong> <input type="text" class="form-control keywordSearchWiki" style="width:263px">
            </div>
            <div class="input-group">
                <strong> wiki ID：</strong> <input placeholder="支持多ID填写 “，” 分割" type="text" class="form-control keywordSearchWikiId" style="width:263px">
            </div>
        </div>
        <div class="img_item_search_result" style="position: relative;">
            <div class="panel storePool"  style="">
                <div class="panel-heading"><span id="title"> </span><span class="close">X</span></div>
                <div class="panel-body">


                </div>
                <div class="panel-bottom"  style="height: 20px;width: 100%; background: #b3b3b3; text-align: center">
                    加载更多
                </div>
            </div>
        </div>
        <div class="img_item_form" >
            <form class="form1" action="/admin/wiki/relateWiki/{{$pic_id}}/relate" method="post" >
                <input type="hidden" name="picId" value="{{$pic['pic_id']}}">
                <div class="input-group goods-group" style="margin-bottom: 20px;" >
                </div>
                <input type="submit" class="btn btn-primary" value="提交"/>
            </form>
        </div>
    </div>
@endforeach


</body>
</html>